// CylonEyes.c
#include <avr/io.h>
#define F_CPU 1000000UL
#include <util/delay.h>

int main (void)
{	
	int i = 0;

	// set PORTD for output
	DDRD= 0xFF;

	while(1) {
		

		for(i = 1; i < 128; i = i*2)
		{
			PORTD = i;
			_delay_loop_2(30000);
		}	
			
		for(i = 128; i > 1; i -= i/2)
		{
			PORTD = i;
			_delay_loop_2(30000);
		}	
	}
	
	return 1;
}
